home *** CD-ROM | disk | FTP | other *** search
/ Garbo / Garbo.cdr / mac / hypercrd / hc2_x / tcprogud.sit / TC Prog Guide / card_15503.txt < prev    next >
Text File  |  1991-02-27  |  797b  |  29 lines

  1. -- card: 15503 from stack: in
  2. -- bmap block id: 0
  3. -- flags: 0000
  4. -- background id: 4755
  5. -- name: 
  6.  
  7.  
  8. -- part contents for background part 4
  9. ----- text -----
  10. by a semicolon.
  11.  
  12. However, the trailing semicolon IS required in the struct declaration since its syntax requires an additional statement following the compound statement.  In this case this statement is simply the "null" statement: a lone semicolon following the closing brace.
  13.  
  14. Also note that some programmers prefer an alternate bracket format which is treated identically by the compiler (since line feeds are ignored "white space"):
  15.  
  16.     struct Person:indirect {
  17.         int     age;
  18.         int     weight;
  19.  
  20.         void    set(void);
  21.         void    print(void);
  22.     };   
  23.  
  24.  
  25.  
  26.  
  27. -- part contents for background part 7
  28. ----- text -----
  29. 23